import request from '/@/utils/request';


interface editPassword {
	id: string
	newPassword:string
}
//获取地区列表

export function regionGet(params: object) {
	return request({
		url: '/api/region',
		method: 'get',
		params: params,
	});
}
//用户列表


export function userList(params: object) {
	return request({
		url: '/api/center/account',
		method: 'get',
		params: params,
	});
}
//用户添加
export function userAdd(params: object) {
	return request({
		url: '/api/center/account',
		method: 'post',
		data: params,
	});
}
//用户编辑
export function userEdit(params: object) {
	return request({
		url: '/api/center/account/editAccount',
		method: 'post',
		data: params,
	});
}
//所属高校
export function universities(params: object) {
	return request({
		url: '/api/center/school/tree',
		method: 'get',
		data: params,
	});
}
//删除
export function deleteRow(params: editPassword) {
	return request({
		url: `/api/center/account/deleteAccount?id=${params.id}` ,
		method: 'post',
		data: params,
	});
}
//重置密码
export function resetNewPass(params: editPassword) {
	return request({
		url: `/api/center/account/updatePassword?id=${params.id}&newPassword=${params.newPassword}` ,
		method: 'post',
		data: params,
	});
}



